import request from '@/utils/request'

// 查询新闻要闻列表
export function listImportantnews(query) {
  return request({
    url: '/business/importantnews/list',
    method: 'get',
    params: query
  })
}

// 查询新闻要闻详细
export function getImportantnews(id) {
  return request({
    url: '/business/importantnews/' + id,
    method: 'get'
  })
}

// 新增新闻要闻
export function addImportantnews(data) {
  return request({
    url: '/business/importantnews',
    method: 'post',
    data: data
  })
}

// 修改新闻要闻
export function updateImportantnews(data) {
  return request({
    url: '/business/importantnews',
    method: 'put',
    data: data
  })
}

// 删除新闻要闻
export function delImportantnews(id) {
  return request({
    url: '/business/importantnews/' + id,
    method: 'delete'
  })
}
